<?php
require 'basehandle.php';
require '../dao/userdao.php';

class Overload implements basehandle{
	public function dohandle(){
		$mission=$_POST['mission'];
		$userid=$_POST['userid'];
		$coin=$_POST['coin'];
		$dao=new userdao();
 		$rs=$dao->overmiss($mission,$userid);
 		$rs1=$dao->overcoin($coin,$userid);
 		//var_dump($rs);
 		error_log($mission);
 		error_log($userid);
 		error_log($coin);
		if(!empty($rs) && !empty($rs1)){
			$info=array("rs"=>"success",
				"successinf"=>"成功");
		}
		else{
			$info=array("rs"=>"error","errorinf"=>"失败");
		}
		echo json_encode($info);
	}
	
}  
?>